﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace DataInterpolator.Model
{
   public interface IDataService
   {
      event Action<string> StatusMessage;
      event Action<PartialUpdateTypes> WellDataUpdated;

      void SetLeftWell(string wellTitle);

      void SetRightWell(string wellTitle);


      //Options
      void SetSamplingDistance(double distanceFeet);
      void SetInterpolationLevels(int levelCount);

      void SetInterpolationPairs(IList<InterpPair> pairs);

      void GetInterpolatedValues(Action<DataSet, IList<DataSet>, DataSet, double, double> callback);

      void NewDatabase();

      bool UnsavedChanges();

      string SaveDatabaseFile(bool showDialog);
      bool LoadDatabaseFile(string filename);

      void ImportLogFiles(IList<string> fileNames);
      void RemoveWells(IList<Guid> wellIDs);

      void GetWellData(Action<IList<Well>> callback);
      void UpdateWell(Guid id, Func<Well, bool> callback);

      bool SetZeroRef(string refPoint);
      void SetTopFormation(string topFormationTitle);
      void SetBotFormation(string botFormationTitle);
      bool SetWindow(double minValue, double maxValue);

      bool ExportInterpolation(ExportInterpInfo exportInfo);
   }
}
